package com.des1gn.ymgetil.thread;

import java.util.concurrent.*;

/**
 * @Description:
 * @Author: Des1gn
 * @Date: 2019/9/6 16:42
 */
public class ExecutorPool {

    private static final ExecutorService executorService = new ThreadPoolExecutor(
            20, 1000, 10000L, TimeUnit.MILLISECONDS, new LinkedBlockingQueue<Runnable>(1024));

    public static void submit(FutureTask futureTask){
        executorService.submit(futureTask);
    }

    public static void submit(Runnable runnable){
        executorService.submit(runnable);
    }



}
